package hjw.com.service;

import hjw.com.dao.HotMapper;
import hjw.com.entity.Hot;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
 * <p>Project:Academic - HotServiceImpl
 *
 * @author IvanWei玮 -- maste
 * @version 1.0
 * @DataTime 2025/1/21 22:05
 * @since 1.8
 */
@Service
public class HotServiceImpl implements HotService{
    private final HotMapper hotMapper;

    @Autowired
    public HotServiceImpl(HotMapper hotMapper) {
        this.hotMapper = hotMapper;
    }

    @Override
    public List<Hot> findByParam(Map<String, Object> map) {
        return hotMapper.findByParam(map);
    }

    @Override
    public int delete(Integer id) {
        return hotMapper.delete(id);
    }

    @Override
    public int updateById(Map<String, Object> map) {
        return hotMapper.updateById(map);
    }

    @Override
    public int add(Hot hot) {
        return hotMapper.add(hot);
    }
}
